#include <windows.h> 

#define D0 0

#define M1 587
#define M2 659
#define M3 740
#define M4 784
#define M5 880
#define M6 988
#define M7 1109

#define H1 1175
#define H2 1318
#define H3 1480

int tune[]= {
	M5,
	M5,M3,M4,M5,
	M7,M6,
	M5,M5,M2,M3,
	M4,
	M1,
	M2,
	M5,M5,M5,M5,M3,M4,
	M5,H1,
	M6,M6,M6,M6,M4,M6,
	M5,D0,
	M5,M5,M5,M5,M7,M6,
	M5,M4,M4,D0,
	M4,M4,M4,M4,M3,M2,
	M1,D0,
	M5,M5,M5,M5,M3,M4,
	M5,H1,
	M6,M6,M6,M6,M4,M6,
	M5,D0,
	M5,M5,M5,M5,M7,M6,
	M5,M4,M4,D0,
	M4,M4,M4,M4,M3,M2,
	M1,D0,
	H1,H1,H1,H1,M5,M6,
	H1,H1,H3,
	H2,H2,H2,H2,H1,M7,
	M6,M6,D0,
	M7,M7,M7,M7,M7,H1,
	H2,M5,D0,
	M7,M7,H1,H2,H1,M7,
	H1,D0,
	M5,
	M5,M3,M4,M5,
	M7,M6,
	M5,M5,M2,M3,
	M4,
	M1,
	M2,
	M5,M5,M5,M5,M3,M4,
	M5,H1,
	M6,M6,M6,M6,M4,M6,
	M5,D0,
	M5,M5,M5,M5,M7,M6,
	M5,M4,M4,D0,
	M4,M4,M4,M4,M3,M2,
	M1,D0,
	M5,M5,M5,M5,M3,M4,
	M5,H1,
	M6,M6,M6,M6,M4,M6,
	M5,D0,
	M5,M5,M5,M5,M7,M6,
	M5,M4,M4,D0,
	M4,M4,M4,M4,M3,M2,
	M1,D0,
	H1,H1,H1,H1,M5,M6,
	H1,H1,H3,
	H2,H2,H2,H2,H1,M7,
	M6,M6,D0,
	M7,M7,M7,M7,M7,H1,
	H2,M5,D0,
	M7,M7,H1,H2,H1,M7,
	H1,D0,
	H1,H1,H1,M5,M6,
	H1,H3,
	H2,H2,H2,H1,M7,
	M6,
	M7,M7,M7,M7,H1,
	H2,M5,
	M7,M7,H1,H2,H1,M7,
	H1,
	H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